package br.com.games.daedal.ui;

import br.com.games.daedal.DaedalTeam;
import br.com.games.daedal.Vertex;
import br.com.games.daedal.ia.Ares;
import br.com.games.daedal.imp.DaedalBoard;
import br.com.games.hefesto.Game;
import br.com.games.hefesto.Move;

public class SwingPlayer extends Ares {

	/**
	 * Criar
	 * @param team
	 */
	public SwingPlayer(DaedalUI ui, DaedalTeam team) {
		super(team, 2);
		this.ui=ui;
	}
	
	/*
	 * (non-Javadoc)
	 * @see br.com.games.hefesto.ai.Atena#getMove(br.com.games.hefesto.Game)
	 */
	@Override
	public Move<Vertex> getMove(Game<? extends DaedalBoard, Vertex> game) {
		Move<Vertex> result = null;
		ui.waitMove(true);
		result = ui.getMove();
		ui.waitMove(false);
		return result;
	}
	
	
	/**
	 * Campos privados
	 */
	private DaedalUI ui;
}
